
(* Data types *)
type event =
  Completion |
  Release |
  ZeroLax ;;
  
type jobState =
  Running |
  Paused |
  Completed ;;

type eventObject = {
  eventType : event;
  eventLength : float;
  creatingJob : int;
} ;;

(* Job class *)
class job :
  float -> 
  float ->
  int ->
  out_channel ->
  
  object
	
	method advanceClock : eventObject -> float -> unit
  method decTimeUntilDeadline : eventObject -> unit
  method decWorkRemaining : eventObject -> float -> unit
  method getDeadline : float
  method getJID : int
  method getNextEvent : eventObject
  method getPeriod : float
  method getWork : float
  method getStatus : jobState 
  method jobFinished : bool
  method laxity : float
  method periodFinished : bool
  method releaseJob : unit
  method setCompleted : float -> unit
  method setPaused : float -> unit
  method setRunning : float -> unit
  
 end